MyUserPaneActivateProc
NEW WITH THE APPEARANCE MANAGER
Handles activate and deactivate event processing.The Control Manager declares the type for an application-defined user pane activate function as follows:
typedef pascal void (*ControlUserPaneActivateProc)( ControlHandle control, Boolean activating);The Control Manager defines the data typeUserPaneActivateUPP
to identify the universal procedure pointer for this application-defined function:
typedef UniversalProcPtr ControlUserPaneActivateUPP;You typically use theNewControlUserPaneActivateProc
macro like this:
ControlUserPaneActivateUPP myControlUserPaneActivateUPP; myControlUserPaneActivateUPP = NewControlUserPaneActivateProc (MyUserPaneActivate);You typically use theCallControlUserPaneActivateProc
macro like this:
CallControlUserPaneActivateProc(myControlUserPaneActivateUPP, control, activating);Here's how to declare the functionMyUserPaneActivateProc:
pascal void MyUserPaneActivateProc ( ControlHandle control Boolean activating);
control
- A handle to the control in which the activate event occurred.
activating
- A Boolean value indicating whether or not the control is being activated. If
true
, the control is being activated. Iffalse
, the control is being deactivated.DISCUSSION
YourMyUserPaneActivateProc
function should perform any special processing before the user pane becomes activated or deactivated. For example, it should deactivate itsTEHandle
orListHandle
if the user pane is about to be deactivated.This function will only get called if you've set the
kControlWantsActivate
feature bit on creation of the user pane control. Once you have created the functionMyUserPaneActivateProc
, passkControlUserPaneActivateProcTag
in thetagName
parameter ofSetControlData
.